/**
 * 约定：如下常量必须成对出现，每对常量代表一对 撤销操作 和 反撤操作
 * 撤销操作常量必须出现在 UndoType.list 数组中的偶数处位置 n（n % 2 === 0），对应的反撤操作常量必须紧随其后，也是就是 n+1
 * @type {string}
 */
const addEye = 'addEye';
const removeEye = 'removeEye';
const addSampleCube = 'addSampleCube';
const removeSampleCube = 'removeSampleCube';
const updateEye = 'updateEye';
const updateEyeUndo = 'updateEyeUndo';
const addWorkArea = 'addWorkArea';
const removeWorkArea = 'removeWorkArea';
const setWorkAreaColor = 'setWorkAreaColor';
const unsetWorkAreaColor = 'unsetWorkAreaColor';
// 可能引起工作区的新增和修改
const addHole = 'addHole';
const removeHole = 'removeHole';
const replaceHole = 'replaceHole'; // 替换孔洞
const replaceHoleUndo = 'replaceHoleUndo';
const shapeHole = 'shapeHole'; // 修改孔洞的形状
const shapeHoleUndo = 'shapeHoleUndo';
// 无人机喷涂动画的航线编辑
const addSprayPathPoint = 'addSprayPathPoint';
const addSprayPathPointUndo = 'addSprayPathPointUndo';
// 障碍物标定
const transformBlocking = 'transformBlocking';
const unTransformBlocking = 'unTransformBlocking';
const addBlocking = 'addBlocking';
const removeBlocking = 'removeBlocking';
// 墙面标定
const addPlaneRefPoint = 'addPlaneRefPoint';
const removePlaneRefPoint = 'removePlaneRefPoint';
// 切割线添加
const addSliceSegment = 'addSliceSegment';
const removeSliceSegment = 'removeSliceSegment';
// 航点添加
const addRoutePoint = 'addRoutePoint'
const removeRoutePoint = 'removeRoutePoint'
// 航点移动
const moveRoutePoint = 'moveRoutePoint'
const unMoveRoutePoint = 'unMoveRoutePoint'
// 航线添加
const addRoute = 'addRoute'
const removeRoute = 'removeRoute'

export default class UndoType {
  static addEye = addEye;
  static removeEye = removeEye;
  static addSampleCube = addSampleCube;
  static removeSampleCube = removeSampleCube;
  static updateEye = updateEye;
  static updateEyeUndo = updateEyeUndo;
  static addWorkArea = addWorkArea;
  static removeWorkArea = removeWorkArea;
  static setWorkAreaColor = setWorkAreaColor;
  static unsetWorkAreaColor = unsetWorkAreaColor;
  static addHole = addHole;
  static removeHole = removeHole;
  static replaceHole = replaceHole;
  static replaceHoleUndo = replaceHoleUndo;
  static shapeHole = shapeHole;
  static shapeHoleUndo = shapeHoleUndo;
  static addSprayPathPoint = addSprayPathPoint;
  static addSprayPathPointUndo = addSprayPathPointUndo;
  static transformBlocking = transformBlocking;
  static unTransformBlocking = unTransformBlocking;
  static addBlocking = addBlocking;
  static removeBlocking = removeBlocking;
  static addPlaneRefPoint = addPlaneRefPoint;
  static removePlaneRefPoint = removePlaneRefPoint;
  static addSliceSegment = addSliceSegment;
  static removeSliceSegment = removeSliceSegment;
  static addRoutePoint = addRoutePoint;
  static removeRoutePoint = removeRoutePoint;
  static moveRoutePoint = moveRoutePoint;
  static unMoveRoutePoint = unMoveRoutePoint;
  static addRoute = addRoute;
  static removeRoute = removeRoute;
  static list = [
    addEye,
    removeEye,
    addSampleCube,
    removeSampleCube,
    updateEye,
    updateEyeUndo,
    addWorkArea,
    removeWorkArea,
    addSprayPathPoint,
    addSprayPathPointUndo,
    setWorkAreaColor,
    unsetWorkAreaColor,
    addHole,
    removeHole,
    replaceHole,
    replaceHoleUndo,
    shapeHole,
    shapeHoleUndo,
    transformBlocking,
    unTransformBlocking,
    addBlocking,
    removeBlocking,
    addPlaneRefPoint,
    removePlaneRefPoint,
    addSliceSegment,
    removeSliceSegment,
    addRoutePoint,
    removeRoutePoint,
    moveRoutePoint,
    unMoveRoutePoint,
    addRoute,
    removeRoute,
  ];
}
